﻿using System;
using System.Collections.Generic;

namespace YJ.Data.Interface
{
    public interface IDocumentsReadUsers
    {
        /// <summary>
        /// 新增
        /// </summary>
        int Add(YJ.Data.Model.DocumentsReadUsers model);

        /// <summary>
        /// 更新
        /// </summary>
        int Update(YJ.Data.Model.DocumentsReadUsers model);

        /// <summary>
        /// 查询所有记录
        /// </summary>
        List<YJ.Data.Model.DocumentsReadUsers> GetAll();

        /// <summary>
        /// 查询单条记录
        /// </summary>
        Model.DocumentsReadUsers Get(Guid documentid, Guid userid);

        /// <summary>
        /// 删除
        /// </summary>
        int Delete(Guid documentid, Guid userid);

        /// <summary>
        /// 查询记录条数
        /// </summary>
        long GetCount();
        /// <summary>
        /// 删除记录
        /// </summary>
        int Delete(Guid documentid);

        /// <summary>
        /// 更新一个文档为已读
        /// </summary>
        /// <param name="docID"></param>
        /// <param name="userID"></param>
        void UpdateRead(Guid docID, Guid userID);
    }
}
